package aom.ju.ss.view.user.shop.management.order

import android.os.Bundle
import androidx.core.content.ContextCompat
import androidx.fragment.app.Fragment
import aom.ju.ss.R
import aom.ju.ss.databinding.ListBinding
import aom.ju.ss.databinding.OrderListFragmentBinding
import aom.ju.ss.databinding.OrderManageBinding
import aom.ju.ss.utils.http.LP_API
import aom.ju.ss.utils.show
import aom.ju.ss.view.base.BaseActivity
import aom.ju.ss.view.base.BaseFragment
import aom.ju.ss.view.base.BaseListFragment
import aom.ju.ss.view.base.TopBar
import aom.ju.ss.view.main.LpViewModel

/**
 * 售后 列表
 */
class OrderListItemSHFragment : BaseListFragment() {

    companion object {
        fun getMy(type: String): OrderListItemSHFragment {
            val f = OrderListItemSHFragment()
            val b = Bundle()
            b.putString("type", type)
            f.arguments = b
            return f
        }
    }

    var fs = arrayListOf<Fragment>()

    override fun api(): String {
        return LP_API.shop_order_after_sale_get_list
    }

    override fun key(): Array<String> {
        return arrayOf("type", "page")
    }

    override fun value(): Array<String> {
        return arrayOf(requireArguments().getString("type", ""), page.toString())
    }

    override fun ok(jsonString: String, httpTY: String) {
        super.ok(jsonString, httpTY)
        setList(null)
    }

    override fun error(e: String?, jsonString: String?, httpTY: String?) {
        super.error(e, jsonString, httpTY)
        e?.show
    }

    override fun onBaseCreateView() {
        super.onBaseCreateView()

    }


}